home *** CD-ROM | disk | FTP | other *** search
/ Chip 1996 November / Chip 11-96.iso / treiber / grafik / miro / crystal / cr24s / win_nt / 24snt.exe / OEMSETUP.INF < prev    next >
INI File  |  1995-04-04  |  17KB  |  378 lines

  1. [Identification]
  2.     OptionType = VIDEO
  3.  
  4. [LanguagesSupported]
  5.     ENG
  6.  
  7. [ProgressCopyENG]
  8.     ProCaption   = "Windows NT Setup"
  9.     ProCancel    = "Cancel"
  10.     ProCancelMsg = "Windows NT is not correctly installed.  Are you sure you want "+
  11.                    "to cancel copying files?"
  12.     ProCancelCap = "Setup Message"
  13.     ProText1     = "Copying:"
  14.     ProText2     = "To:"
  15.  
  16. [StringsENG]
  17.     String1 = "Display"
  18.     String2 = "Please enter the full path to the Windows NT Display "+
  19.               "driver files.  If you want to install files from the "+
  20.               "original Setup floppy disks, type a drive letter (such "+
  21.               "as A:) and Setup will prompt you for the correct disk.  "+
  22.               "Then choose Continue."
  23.  
  24. [Source Media Descriptions]
  25.     1 = "miro.plus high-speed drivers setup disk #1.00", TAGFILE = miro100
  26.  
  27. [OptionsTextENG]
  28.     "crystals" = "miroCRYSTAL 32S/24S/16S, S4, Win"
  29.  
  30. [Options]
  31.     "crystals" = crystals
  32.  
  33. [MiniportDrivers]
  34.     crystals = crystals, !SERVICE_KERNEL_DRIVER, Video, !SERVICE_ERROR_NORMAL, {crystals}, 0, "%SystemRoot%\System32\IoLogMsg.dll" , 7, 1, {}, noconfig
  35.  
  36. [Files-DisplayDLLs]
  37.     crystals = 1, CRYSTALS.DLL, SIZE=110000
  38.  
  39. [Files-DisplayMiniportDrivers]
  40.     crystals = 1, CRYSTALS.SYS, SIZE=70000
  41.  
  42. [Files-Other]
  43.  
  44. [OpenGLDrivers]
  45.  
  46. [Identify]
  47.     read-syms Identification
  48.     set Status     = STATUS_SUCCESSFUL
  49.     set Identifier = $(OptionType)
  50.     set Media      = #("Source Media Descriptions", 1, 1)
  51.     Return $(Status) $(Identifier) $(Media)
  52.  
  53. [ServicesEntry]
  54.     CurrentEntry = "" ? $(!LIBHANDLE) GetDevicemapValue Video \Device\Video0
  55.  
  56. [SystemVariables]
  57.     STF_WINDOWSSYSPATH = "" ? $(!LIBHANDLE) GetWindowsNtSysDir
  58.     STF_WINDOWSPATH = "" ? $(!LIBHANDLE) GetWindowsNtDir
  59.  
  60. [InstallOption]
  61.     set Status       = STATUS_FAILED
  62.     set DrivesToFree = {}
  63.     set !Option   = $($1)
  64.     set SrcDir    = $($2)
  65.     set AddCopy   = $($3)
  66.     set DoCopy    = $($4)
  67.     set DoConfig  = $($5)
  68.     set DoInstall = $($6)
  69.     set LanguageList = ^(LanguagesSupported, 1)
  70.     Ifcontains(i) $($0) in $(LanguageList)
  71.     else
  72.         set Status = STATUS_NOLANGUAGE
  73.         goto finish_InstallOption
  74.     endif
  75.     read-syms Strings$($0)
  76.     ifstr(i) $(!Option) != "DETECT"
  77.         set OptionList = ^(Options, 0)
  78.         ifcontains $(!Option) in $(OptionList)
  79.         else
  80.             goto finish_InstallOption
  81.         endif
  82.         set OptionList = ""
  83.         set DriverEntry       =   #(Options, $(!Option), 1)
  84.         set MiniportDriver    =   #(MiniportDrivers, $(DriverEntry), 1)
  85.         set InstalledDisplays =   #(MiniportDrivers, $(DriverEntry), 5)
  86.         set OtherFiles        =   #(MiniportDrivers, $(DriverEntry), 10)
  87.     endif
  88.     read-syms ServicesEntry
  89.     detect    ServicesEntry
  90.     set DriversList        = ^(MiniportDrivers, 0)
  91.     set MiniportDriverList = ^(Files-DisplayMiniportDrivers, 0)
  92.     set DisplayDriverList  = ^(Files-DisplayDLLs, 0)
  93.     set OpenGLDriverList   = ^(OpenGLDrivers, 0)
  94.     set OtherFilesList     = ^(Files-Other, 0)
  95. installtheoption = +
  96.     ifstr(i) $(AddCopy) == "YES"
  97.         ifstr(i) $(!Option) == "DETECT"
  98.             set DoActualCopy = YES
  99.         else
  100.             set DoActualCopy = NO
  101.             set FileToCheck = #(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  102.             LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\drivers\"$(FileToCheck)
  103.             ifstr(i) $(STATUS) == NO
  104.                 set DoActualCopy = YES
  105.                 goto addfiles
  106.             endif
  107.             ForListDo $(OtherFiles)
  108.                  ifcontains $($) in $(OtherFilesList)
  109.                     set FileToCheck = #(Files-Other, $($), 2)
  110.                     LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\"$(FileToCheck)
  111.                     ifstr(i) $(STATUS) == NO
  112.                         set DoActualCopy = YES
  113.                         goto addfiles
  114.                     endif
  115.                  endif
  116.             EndForListDo
  117.             ForListDo $(InstalledDisplays)
  118.                 ifcontains $($) in $(DisplayDriverList)
  119.                     set FileToCheck = #(Files-DisplayDLLs, $($), 2)
  120.                     LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\"$(FileToCheck)
  121.                     ifstr(i) $(STATUS) == NO
  122.                         set DoActualCopy = YES
  123.                         goto addfiles
  124.                     endif
  125.                     ifcontains $($) in $(OpenGLDriverList)
  126.                         set FileToCheck = #(Files-DisplayOpenGLDrivers, #(OpenGLDrivers, $($), 1), 2)
  127.                         LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\"$(FileToCheck)
  128.                         ifstr(i) $(STATUS) == NO
  129.                             set DoActualCopy = YES
  130.                             goto addfiles
  131.                         endif
  132.                     endif
  133.                 endif
  134.             EndForListDo
  135.         endif
  136. addfiles = +
  137.         ifstr(i) $(DoActualCopy) == NO
  138.             shell "subroutn.inf" DriversExist $($0) $(String1)
  139.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  140.                 Debug-Output "VIDEO.INF: shelling DriversExist failed"
  141.                 goto finish_InstallOption
  142.             endif
  143.             ifstr(i) $($R0) == STATUS_CURRENT
  144.             else-ifstr(i) $($R0) == STATUS_NEW
  145.                 set DoActualCopy = YES
  146.             else-ifstr(i) $($R0) == STATUS_USERCANCEL
  147.                 Debug-Output "VIDEO.INF: User cancelled video installation"
  148.                 goto finish_InstallOption
  149.             else
  150.                 Debug-Output "VIDEO.INF: Error reported in DriversExist routine in SUBROUTN.INF"
  151.                 goto finish_InstallOption
  152.             endif
  153.         endif
  154.         ifstr(i) $(DoActualCopy) == YES
  155.             shell "registry.inf" GetNTSource
  156.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  157.             else-ifstr(i) $($R0) != STATUS_SUCCESSFUL
  158.             else
  159.                 set SrcDir = $($R1)
  160.             endif
  161.             shell "subroutn.inf" DoAskSourceEx $(SrcDir) $(String2)
  162.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  163.                 Debug-Output "VIDEO.INF: shelling DoAskSourceEx failed"
  164.                 goto finish_InstallOption
  165.             endif
  166.             ifstr(i) $($R0) == STATUS_SUCCESSFUL
  167.                 set SrcDir = $($R1)
  168.                 ifstr(i) $($R2) != ""
  169.                     set DrivesToFree = >($(DrivesToFree), $($R2))
  170.                 endif
  171.             else
  172.                 Debug-Output "VIDEO.INF: User cancelled asking source."
  173.                 goto finish_InstallOption
  174.             endif
  175.             ifstr(i) $(!Option) != "DETECT"
  176.                 install Install-AddCopyOption
  177.             else
  178.                 install Install-AddAllCopy
  179.             endif
  180.             ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  181.                 Debug-Output "VIDEO.INF: Adding video files to copy list failed"
  182.                 goto finish_InstallOption
  183.             endif
  184.         else
  185.             set DoCopy = NO
  186.         endif
  187.     endif
  188.     ifstr(i) $(DoCopy) == "YES"
  189.         read-syms ProgressCopy$($0)
  190.         install Install-DoCopyOption
  191.         ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_FAILURE"
  192.             Debug-Output "Copying files failed"
  193.             goto finish_InstallOption
  194.         else-ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_USERQUIT"
  195.             set Status = STATUS_USERCANCEL
  196.             goto finish_InstallOption
  197.         endif
  198.     endif
  199.     ifstr(i) $(DoConfig) == "YES"
  200.         shell "registry.inf" CheckSetupModify
  201.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  202.             goto finish_InstallOption
  203.         endif
  204.         ifstr(i) $($R0) != STATUS_SUCCESSFUL
  205.             goto finish_InstallOption
  206.         endif
  207.         ForListDo $(DriversList)
  208.             ifstr(i) $(!Option) == "DETECT"
  209.                 set DriverEntry = $($)
  210.                 set DeviceDescription = ""
  211.                 set ErrorControl      = $(!SERVICE_ERROR_IGNORE)
  212.                 ifcontains #(MiniportDrivers, $(DriverEntry), 1) in $(MiniportDriverList)
  213.                     ifint #(MiniportDrivers, $(DriverEntry), 9) == 1
  214.                         set configDriver = YES
  215.                     else
  216.                         set configDriver = NO
  217.                     endif
  218.                 else
  219.                     set configDriver = NO
  220.                 endif
  221.             else
  222.                 set DeviceDescription = $(!Option)
  223.                 set ErrorControl      = $(#(MiniportDrivers, $(DriverEntry), 4))
  224.                 ifstr(i) $(DriverEntry) == $($)
  225.                     set configDriver = YES
  226.                 else
  227.                     set configDriver = NO
  228.                 endif
  229.             endif
  230.             ifstr(i) $(configDriver) == YES
  231.                 Debug-Output "configuring the miniport driver"
  232.                 set MiniportDriver    =   #(MiniportDrivers, $(DriverEntry), 1)
  233.                 set Type              = $(#(MiniportDrivers, $(DriverEntry), 2))
  234.                 set Group             =   #(MiniportDrivers, $(DriverEntry), 3)
  235.                 set InstalledDisplays =   #(MiniportDrivers, $(DriverEntry), 5)
  236.                 set VgaCompatible     =   #(MiniportDrivers, $(DriverEntry), 6)
  237.                 set EventMessageFile  =   #(MiniportDrivers, $(DriverEntry), 7)
  238.                 set TypesSupported    =   #(MiniportDrivers, $(DriverEntry), 8)
  239.                 set ServiceNode   = $(DriverEntry)
  240.                 set ServiceBinary = %SystemRoot%\System32\drivers\#(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  241.                 set ServicesValues = { +
  242.                         {Type,           0, $(!REG_VT_DWORD),     $(Type)                  }, +
  243.                         {Group,          0, $(!REG_VT_SZ),        $(Group)                 }, +
  244.                         {ErrorControl,   0, $(!REG_VT_DWORD),     $(ErrorControl)          }, +
  245.                         {BinaryPathName, 0, $(!REG_VT_EXPAND_SZ), $(ServiceBinary)         }  +
  246.                         }
  247.                 ifstr(i) $(DoInstall) == "YES"
  248.                     set ServicesValues = >($(ServicesValues), +
  249.                             {Start,          0, $(!REG_VT_DWORD),     $(!SERVICE_SYSTEM_START) })
  250.                 else
  251.                     set ServicesValues = >($(ServicesValues), +
  252.                             {Start,          0, $(!REG_VT_DWORD),     $(!SERVICE_DISABLED)     })
  253.                 endif
  254.                 set !ParametersValues = { +
  255.                         {"Device Description",        0, $(!REG_VT_SZ),       $(DeviceDescription) }, +
  256.                         {InstalledDisplayDrivers,     0, $(!REG_VT_MULTI_SZ), $(InstalledDisplays) }, +
  257.                         {VgaCompatible,               0, $(!REG_VT_DWORD),    $(VgaCompatible)     }, +
  258.                         {DefaultSettings.BitsPerPel,  0, $(!REG_VT_DWORD),    0                    }, +
  259.                         {DefaultSettings.VRefresh,    0, $(!REG_VT_DWORD),    0                    }, +
  260.                         {DefaultSettings.Interlaced,  0, $(!REG_VT_DWORD),    0                    }, +
  261.                         {DefaultSettings.XResolution, 0, $(!REG_VT_DWORD),    0                    }, +
  262.                         {DefaultSettings.YResolution, 0, $(!REG_VT_DWORD),    0                    }  +
  263.                         }
  264.                 ifstr(i) $(!Option) != "DETECT"
  265.                     shell "" #(MiniportDrivers, $(DriverEntry), 11)
  266.                 endif
  267.                 set DeviceValues = {}
  268.                 set EventLogValues = { +
  269.                         {EventMessageFile, 0, $(!REG_VT_EXPAND_SZ), $(EventMessageFile) }, +
  270.                         {TypesSupported,   0, $(!REG_VT_DWORD),     $(TypesSupported)   }  +
  271.                         }
  272.                 shell "registry.inf"  MakeServicesEntry $(ServiceNode)       +
  273.                                                         $(ServicesValues)    +
  274.                                                         $(!ParametersValues) +
  275.                                                         $(DeviceValues)      +
  276.                                                         $(EventLogValues)    +
  277.                                                         Device0
  278.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  279.                     Debug-Output "Couldn't execute MakeServicesEntry in registry.inf"
  280.                     goto finish_InstallOption
  281.                 endif
  282.                 ifstr(i) $($R0) != STATUS_SUCCESSFUL
  283.                     Debug-Output "MakeServicesEntry failed for video"
  284.                     goto finish_InstallOption
  285.                 endif
  286.                 ForListDo $(InstalledDisplays)
  287.                     ifcontains $($) in $(OpenGLDriverList)
  288.                         set KeyPath = { +
  289.                                 {SOFTWARE,       0, $(MaskAllAccess)}, +
  290.                                 {Microsoft,      0, $(MaskAllAccess)}, +
  291.                                 {"Windows NT",   0, $(MaskAllAccess)}, +
  292.                                 {CurrentVersion, 0, $(MaskAllAccess)}, +
  293.                                 {OpenGLDrivers,  0, $(MaskAllAccess)}  +
  294.                                 }
  295.                         set KeyValue = { +
  296.                                 {$($), 0, $(!REG_VT_SZ), #(OpenGLDrivers, $($), 1) } +
  297.                                 }
  298.                         shell "registry.inf" CreateKey $(!REG_H_LOCAL) $(KeyPath) $(KeyValue)
  299.                         Debug-Output "just did an OGL section"
  300.                         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  301.                             Debug-Output "Couldn't execute CreateKey in registry.inf"
  302.                             goto endInstallOpenGLDriver
  303.                         endif
  304.                         ifstr(i) $($R0) != STATUS_SUCCESSFUL
  305.                             Debug-Output "CreateKey failed for OGLDrivers"
  306.                             goto endInstallOpenGLDriver
  307.                         endif
  308.                         Debug-Output "VIDEO.INF: success installing an ogl entry"
  309.                     endif
  310.                 EndForListDo
  311.             endif
  312.         EndForListDo
  313.     endif
  314.     set Status = STATUS_SUCCESSFUL
  315. finish_InstallOption = +
  316.     ForListDo $(DrivesToFree)
  317.         LibraryProcedure STATUS,$(!LIBHANDLE), DeleteNetConnection $($) "TRUE"
  318.     EndForListDo
  319.     Return $(Status)
  320.  
  321. [Install-AddCopyOption]
  322.     Debug-Output "adding to copy list"
  323.     set STF_VITAL = ""
  324.  
  325.     AddSectionKeyFileToCopyList   Files-DisplayMiniportDrivers   +
  326.                                   $(MiniportDriver)              +
  327.                                   $(SrcDir)                      +
  328.                                   $(!STF_WINDOWSSYSPATH)\drivers
  329.  
  330.     ForListDo $(OtherFilesList)
  331.         ifcontains $($) in $(OtherFiles)
  332.             Debug-Output "adding other files to copy list"
  333.             AddSectionKeyFileToCopyList   Files-Other                +
  334.                                           $($)                       +
  335.                                           $(SrcDir)                  +
  336.                                           $(!STF_WINDOWSSYSPATH)
  337.         endif
  338.     EndForListDo
  339.  
  340.     ForListDo $(InstalledDisplays)
  341.         ifcontains $($) in $(DisplayDriverList)
  342.             Debug-Output "adding display driver to copy list"
  343.             AddSectionKeyFileToCopyList   Files-DisplayDLLs          +
  344.                                           $($)                       +
  345.                                           $(SrcDir)                  +
  346.                                           $(!STF_WINDOWSSYSPATH)
  347.             ifcontains $($) in $(OpenGLDriverList)
  348.                 Debug-Output "adding opengl driver to copy list"
  349.                 AddSectionKeyFileToCopyList   Files-DisplayOpenGLDrivers +
  350.                                               #(OpenGLDrivers, $($), 1)  +
  351.                                               $(SrcDir)                  +
  352.                                               $(!STF_WINDOWSSYSPATH)
  353.             endif
  354.         endif
  355.     EndForListDo
  356.     exit
  357.  
  358. [Install-AddAllCopy]
  359.     Debug-Output "adding all drivers to copy list"
  360.     set STF_VITAL = ""
  361.     AddSectionFilesToCopyList  Files-DisplayMiniportDrivers   +
  362.                                $(SrcDir)                      +
  363.                                $(!STF_WINDOWSSYSPATH)\drivers
  364.     AddSectionFilesToCopyList  Files-DisplayDLLs            +
  365.                                $(SrcDir)                    +
  366.                                $(!STF_WINDOWSSYSPATH)
  367.     exit
  368.  
  369. [Install-DoCopyOption]
  370.     CopyFilesInCopyList
  371.     exit
  372.  
  373. [noconfig]
  374.     set !ParametersValues = >($(!ParametersValues), +
  375.       {"DoLinearAddressing", 0, $(!REG_VT_DWORD), 0})
  376.     return
  377.  
  378.